package com.ylr.blog.framework.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ylr.blog.framework.entity.BlogTagEntity;
import com.ylr.blog.framework.entity.BlogTagRelationEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Created by IntelliJ IDEA.
 *
 * @author wyw
 * date: 2023-05-23 11:38:53
 * className: BlogTagRelationMapper
 * version: 1.0
 * description:
 */
@Mapper
public interface BlogTagRelationMapper extends BaseMapper<BlogTagRelationEntity> {

    /**
     * 查询博客关联的博客标签主键列表
     * @param blogId       博客主键
     * @param deleteStatus 删除状态
     * @return 博客标签主键列表
     */
    List<Long> selectTagIdList(@Param("blogId") Long blogId, @Param("deleteStatus") Integer deleteStatus);

    /**
     * 查询博客关联的博客标签列表
     * @param blogId       博客主键
     * @param deleteStatus 删除状态
     * @return 博客标签主键列表
     */
    List<BlogTagEntity> getBlogTagList(@Param("blogId") Long blogId, @Param("deleteStatus") Integer deleteStatus);
}
